package exception;

public class ThrowsDemo {
    public static void main(String[] args) {
         Student lst=new Student();
         try{
             lst.setAge(38);
         }catch (IllegalAgeException e){
             e.printStackTrace();
         }
        System.out.println("刘思甜的年龄为"+lst.getAge());
    }
}

